package com.hexacta.hrs.sandbox.meetings.service.impl;

import org.springframework.transaction.annotation.Transactional;

import com.hexacta.hrs.sandbox.meetings.data.MeetingDAO;
import com.hexacta.hrs.sandbox.meetings.data.MentorDao;
import com.hexacta.hrs.sandbox.meetings.model.Meeting;
import com.hexacta.hrs.sandbox.meetings.service.MeetingService;

/**
 * Administra los Mentores.
 * @author ncortinez
 */

@Transactional
public class MeetingServiceImpl implements MeetingService {
	
	private MentorDao mentorDAO;
	private MeetingDAO meetingDAO;
	
	public MeetingServiceImpl() {
		this.setMentorDAO(new MentorDao());
	}

	public void update(Object o) {
		this.getMentorDAO().saveOrUpdate(o);
		return;
	}
	
	public Meeting findMeetingById(Long id){
		return this.getMeetingDAO().findById(id);
	}

	public MentorDao getMentorDAO() {
		return mentorDAO;
	}

	public void setMentorDAO(MentorDao mentorDAO) {
		this.mentorDAO = mentorDAO;
	}

	public MeetingDAO getMeetingDAO() {
		return meetingDAO;
	}

	public void setMeetingDAO(MeetingDAO meetingDAO) {
		this.meetingDAO = meetingDAO;
	}
}